package com.design.structural.Adapter;

import com.design.structural.Adapter.Animal.Animal;

/**
 * 描述: Adapter的对象模式实现
 *
 * @author YuJunJie
 * @create 2019-04-01 15:29
 */
public class AnimalAdapter implements Robot{
    private Animal animal;

    AnimalAdapter(Animal animal){
        this.animal = animal;
    }

    @Override
    public void cry() {
        animal.say();
    }

    @Override
    public void move() {
        animal.run();
    }
}
